#include <stdio.h>

int main()
{
    FILE* fp_in;
    FILE* fp_out;
    char ch;
    fp_in = fopen("fcopyin.txt", "w");
    while ((ch = getchar()) != '\n')
    {
        if(ch >= 'A' && ch<= 'Z')ch -= 'A' - 'a';
        fputc(ch, fp_in);
    }
    fclose(fp_in);
    fp_in = fopen("fcopyin.txt", "r");
    fp_out = fopen("fcopyout.txt", "w");
    while ((ch = fgetc(fp_in)) != EOF)
    {
        if(ch >= '0' && ch <= '9')fputc(ch, fp_out);
    }    
    fclose(fp_in);
    fclose(fp_out);
    return 0;
}